package ex.controller;

import ex.beans.DataDTO;
import ex.beans.User;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;

/**
 * @program: LearShiroSpringMvc
 * @description:
 * @author: Mr.Dai
 * @create: 2020-03-27 14:38
 **/
@RestController
@RequestMapping("/test")
public class RestfulController {

    @GetMapping("/t1")
    public Object get(){
        User user = new User();
        user.setUsername("admin");
        user.setPassword("1223");
        user.setId(1);
        user.setSalt("sdasdasdasdzxvfegh5uy");
        return DataDTO.OK(user);
    }
}
